#include <stdio.h>

void test1()
{
	char* p;
	
	//p = getchar(); //类型不匹配，其返回值为int和char类型
	//printf("%s\n", p);
	
	//scanf_s("%s", p);
	//printf("%s\n", p);
	
	char s[] = "China";
	p = s;
	printf("%s\n", p);

	//*p = "CCChina";
	//printf("%s\n", p);
}

void test2()
{
	static char* s[] = { "black", "white", "pink", "violet" };
	char** ptr[] = { s + 3, s + 2, s + 1, s }, *** p; 
	p = ptr; //s[3]
	++p;//s[1]
	printf("%s", **p + 1);
}

void test3()
{
	char s[3][10], (*k)[3], * p;
	//p = s;
	//p = k;
	p = s[0];
	//k = s;
}

void test4()
{
	char str[sizeof("ab")];
	printf("%d %d %d\n", sizeof(void*), sizeof(char), sizeof(str)); //4 1 3
}



int main()
{
	//test1();
	//test2();

	test4();

	return 0;
}